<?php
   @include_once("connect.php");

   $gid=$_POST["gid"];
        $sql="SELECT  gid,title,imgid,price,is_own,jieshao,smalltitle,img_1,img_2,img_3,img_4 from `goodlist1`  where gid='$gid'";
        $result=mysqli_query($conn,$sql);
        // print_r($result);
        $obj=array();

        if($result){
           
            while($item=mysqli_fetch_assoc($result)){
            $item["title"]=$item["title"];
            $item["gid"]=$item["gid"];
            $item["imgid"]=$item["imgid"];
            $item["is_own"]=$item["is_own"];
            $item["jieshao"]=$item["jieshao"];
            $item["smalltitle"]=$item["smalltitle"];
            $item["img_1"]=$item["img_1"];
            $item["img_2"]=$item["img_2"];
            $item["img_3"]=$item["img_3"];
            $item["img_4"]=$item["img_4"];
            $item["price"]=$item["price"]*1;
               array_push($obj,$item); 
            }
        }else{
        $obj["status"] = false;
        $obj["msg"] = "sql语句有误";
        $obj["sql"] = $sql;
        }
  
        echo json_encode($obj);

?>